<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
  <%@ page pageEncoding="UTF-8" %>
  <%@page import="com.wobaby.dao.*"%>
  <%@page import="com.wobaby.vo.*"%>
  <%@page import= "java.util.*"%>
 
<HTML><HEAD><TITLE>发通知</TITLE>
<META http-equiv=Content-Type content="text/html; charset=UTF-8">
<META content="MSHTML 6.00.6000.17093" name=GENERATOR>
<META content="" name=Author>
<META content="" name=Keywords>
<META content="" name=Description><LINK 
href="css/jquery-ui-1.8.7.custom.css" type=text/css rel=stylesheet><LINK 
href="css/css.css" type=text/css rel=stylesheet>
<SCRIPT src="js/jquery-1.4.4.min.js"></SCRIPT>

<SCRIPT src="js/jquery-ui-1.8.7.custom.min.js"></SCRIPT>

<SCRIPT src="js/email.min.js">

  </SCRIPT>
</HEAD>
<BODY><INPUT id=emailaddr type=hidden> 
<form action="receive.jsp">
<TABLE width="100%">
  <TBODY>
  <TR>
    <TD vAlign=top>
      <TABLE class=email>
        <TBODY>
        <TR>
          <TD width=40>收件人</TD>
          <TD>
            <!--<DIV class=divtxt id=divtxt></DIV>-->
            <input name="divtxt" type="text" class="divtxt" id="divtxt">
            </TD>
	</TR>
        <TR>
          <TD width=40>主题</TD>
          <TD><label for="divtitle"></label>
            <input name="divtitle" type="text" class="divtitle" id="divtitle"></TD>
	</TR>
	<TR>
          <TD width=40>内容</TD>
          <TD><label for="txtArea"></label>
            <label for="textarea"></label>
            <textarea name="textarea" cols="45" rows="5" class="divarea" id="textarea"></textarea></TD>
	</TR>
	</TBODY></TABLE></TD>
    <TD vAlign=top width=220>
      <DIV class=lxr id=lxr>
      <DIV class=tt>接收人列表</DIV></DIV></TD></TR>
  <TR>
    <TD colSpan=2><INPUT name="提交" type=submit id=send value=发送></TD></TR></TBODY></TABLE>
<DIV id=dialog title="Dialog Title">
<TABLE>
  <TBODY>
  <TR>
    <TD>联系人(666)</TD>
    <TD></TD>
    <TD>收件人</TD>
  <TR>
  <TR>
    <TD>
     
      <%    
	UserVO u1 = (UserVO)request.getSession().getAttribute("UserVO");
	if(u1 == null){
		response.sendRedirect("login.jsp");
		return;
	}
	if(u1.getFunctionType().equals("princpal")) {
	%>
	 <DIV class=left>
      <DIV class=groupclose><INPUT class=groupcloselm_ico type=button>老师</DIV>
      <DIV class=groupSub>
      <%
      UserManagement um = new UserManagement();
      ArrayList<UserVO> pusv = new ArrayList<UserVO>();//接收家长的数组
      ArrayList<UserVO> tusv = new ArrayList<UserVO>();//接收老师的数组
      pusv.addAll(um.listUsersByfunctionType("parents"));
      tusv.addAll(um.listUsersByfunctionType("teacher"));
      for(UserVO user:tusv){   
       %>     
       <DIV class=info title=<%=user.getUserName() %>><%=user.getName() %></DIV>
       <%
       } 
       %>
      </DIV>
      <DIV class=groupclose><INPUT class=groupcloselm_ico type=button>家长</DIV>
      <DIV class=groupSub>
      <%for(UserVO user:pusv){ %>
      <DIV class=info title=<%=user.getUserName() %>><%=user.getName() %></DIV>
      <%
      } }else if(u1.getFunctionType().equals("teacher")) {
       UserManagement um = new UserManagement();
     ArrayList<UserVO> pusv = new ArrayList<UserVO>();
      pusv.addAll(um.listUsersByfunctionType("parents"));
      %>
      <DIV class=left>
      <DIV class=groupclose><INPUT class=groupcloselm_ico type=button>家长</DIV>
      <DIV class=groupSub>
       <%for(UserVO user:pusv){ %>
      <DIV class=info title=<%=user.getUserName() %>><%=user.getName() %></DIV>
      <% 
      }}
      %>
     
      </DIV></TD>
    <TD><IMG src="images/arrow_left.gif"></TD>
    <TD>
      <DIV class=right></DIV></TD>
  <TR></TR></TBODY></TABLE></DIV></form></BODY></HTML>
